<fieldset>
<% columns.each :for => @record do |column| -%>
  <%# is_subsection? column -%>
  <% if is_subsection? column -%>
</fieldset>

<h2><%= column.label %></h2>
<fieldset>
  <div class="row">
    <%= render :partial => 'form', :locals => { :columns => column } %>
  </div>
</fieldset>

<fieldset>

  <%# if is_subform? column -%>
  <% elsif is_subform? column and !override_form_field?(column) -%>
</fieldset>

<h2><%= column.label %></h2>
<fieldset>
    <%#= render :partial => form_partial_for_column(column), :locals => { :column => column } -%>
</fieldset>

<fieldset>

  <%# normal column -%>
  <% else -%>
  <div class="row <%= 'required' if column.required? %>">
    <%= render :partial => form_partial_for_column(column), :locals => { :column => column } -%>
  </div>
  <% end -%>
<% end -%>
</fieldset>
